package com.greenant.store.utils;

import android.app.Activity;
import android.app.Application.ActivityLifecycleCallbacks;
import android.os.Bundle;

public class MyActivityLifecycleCallbacks implements ActivityLifecycleCallbacks
{

    @Override
    public void onActivityCreated(Activity arg0, Bundle arg1)
    {
        try{
            AppExitManager.getInstance().addActivity(arg0);
        }
        catch(Exception e)
        {
            e.printStackTrace();
        }
    }

    @Override
    public void onActivityDestroyed(Activity arg0)
    {
        AppExitManager.getInstance().finishActivity(arg0); 
    }

    @Override
    public void onActivityPaused(Activity arg0)
    {
        
    }

    @Override
    public void onActivityResumed(Activity arg0)
    {
        
    }

    @Override
    public void onActivitySaveInstanceState(Activity activity, Bundle outState)
    {
        
    }

    @Override
    public void onActivityStarted(Activity activity)
    {
        
    }

    @Override
    public void onActivityStopped(Activity activity)
    {
        
    }

}
